
1. 

ʹõӦΪencodeURIComponentǽġĵַתutf-8ʽurl룬
̨ݲҪʹencodeURIComponentʱҪ̨utf-8֧֣formеı뷽ʽ͵ǰҳ뷽ʽͬ
escape ַ69*+-./@_0-9a-zA-Z
encodeURI ַ82!#$&'()*+,-./:;=?@_~0-9a-zA-Z
encodeURIComponent ַ71! '()*-._~0-9a-zA-Z

2.

UrlEncode  encodeURI ĲͬǶԼַĴͬ
ǶԿո + ַĴͬUrlEncode Ʊ
Ὣոת + ַ encodeURI Ὣת %20 

3.

escape0-255unicodeֵбʱ%u****ʽescape
encodeURIencodeURIComponentͬ


4.

escape 

 String ԱмϿɶ ﷨
escape(charstring) charstring Ҫ String  ˵
escape һ charstring ݵµ String  Unicode ʽ пո񡢱㡢Լ ASCII ַ %xx 棬 xx ڱʾַʮ 磬ո񷵻ص "%20"  ֵַ 255  %uxxxx ʽ洢
ڣGlobal 
encodeURI 

رΪЧͳһԴʶ (URI) ַ ﷨
function encodeURI(URIString : String) : String 
URIString ѡʾ URI ַ2007-7-31 ע
encodeURI һѱ URIݸ decodeURI򽫷سʼַencodeURI ַб룺:/;͡?ʹ encodeURIComponent Щַб롣
ڣGlobal 
encodeURIComponent 

رΪͳһԴʶ (URI) Чַ ﷨
function encodeURIComponent(encodedURIString : String) : String 
encodedURIString ѡʾ URI ַ ע
encodeURIComponent һѱ URIݸ decodeURIComponent򽫷سʼַΪ encodeURIComponent ַ룬ע⣬ַһ· /folder1/folder2/default.htmlебҲ룬ַΪ͵ Web ʱЧġַа URI ʹ encodeURI б롣
ڣGlobal  